HR - Employees - REST API
REST POST CancelationEmployee specification
This operation allows to cancel a management action on an employee.
It's possible to cancel : an hiring, a leaving, a company change, a business unit change or erase an employee file.
If you would like to use this service, please contact us to authorize your ERP_SOURCE.
REQUEST
url: /rest/v1/hr/cancelationEmployee
body: JSON format, containing all fields as belowThe table below provide the details of the headers to be used when making the request.
| Header Name | Description |
|---|---|
| client_id | Client id having authorization to the endpoint(To be provided by DALI team) |
| client_secret | Client secret having authorization to the endpoint(To be provided by DALI team) |
Here is the format of the body that you should send:
{
"EMPLOYEE_ERP_ID": {Employee number},
"ERP_SOURCE": {Name of the source system},
"OSMOSE_CODE": {Company OSMOSE code},
"BU_ANALYTICAL_CODE": {Business Unit analytical code},
"ACTION_REASON": {Management act code},
"EVENT_DATE": {Date of the cancelation event _(format: YYYY-MM-DDTHH:MI:SSZ)_},
"VALUE": {Identifier of the graduation (GRADUATION_ID), skill (SKILL_ID) or handicap (HANDICAP_ID) to cancel. Mandatory ONLY with action_reason equals to C-GRAD or C-SKILL or C-HAND. If the value is * then all graduations (C-GRAD) are canceled. Itβs the same with skills (C-SKILL) and handicaps (C-HAND)},
"EFFECTIVE_DATE": {Effective date of the graduation (GRADUATION_DATE), skill (EFFECTIVE_DATE) or handicap (EFFECTIVE_DATE) to cancel. Mandatory ONLY with action_reason equals to C-GRAD or C-SKILL or C-HAND. If VALUE<>"*" then EFFECTIVE_DATE is mandatory otherwise EFFECTIVE_DATE is ignored.}
}The allowed ACTION_REASON codes are:
| ACTION_REASON | Description |
|---|---|
| C-HIR1 | Used to cancel an hiring (including graduations/skills/handicaps data) |
| C-LEA1 | Used to cancel a leaving |
| C-TRA1 | Used to cancel a company change |
| C-MVT1 | Used to cancel a BU change |
| C-CAN1 | Used to erase an employee: personal/professional/organisational /contract/graduations/skills/handicaps data |
| C-GRAD | Used to erase a graduation |
| C-SKILL | Used to erase a skill |
| C-HAND | Used to erase a handicap |
Note: All fields (EMPLOYEE_ERP_ID / ERP_SOURCE / OSMOSE_CODE / BU_ANALYTICAL_CODE / ACTION_REASON / EVENT_DATE) are mandatory
RESPONSE
Here is the response format:
{
"ERROR": {
"CODE": {error code},
"DESCRIPTION": {error description},
"DETAILS": {error details}
}
}If there's no error, the response is:
{
"ERROR": {
"CODE": 0,
"DESCRIPTION": "SUCCESS",
"DETAILS": ""
}
}The different possible errors are:
| CODE | DESCRIPTION | DETAILS |
|---|---|---|
| 500 | Technical error | The given {EMPLOYEE_ERP_ID} is not filled |
| 500 | Technical error | The given {ERP_SOURCE} is not authorized or it is not filled |
| 500 | Technical error | The given {OSMOSE_CODE} is not filled |
| 500 | Technical error | The given {BU_ANALYTICAL_CODE} must be NOT filled for ACTION_REASON C-TRA1. // The given {BU_ANALYTICAL_CODE} is not filled |
| 500 | Technical error | The given {ACTION_REASON} is not correct or it is not filled, please send one of the following values : 'C-HIR1', 'C-LEA1', 'C-TRA1', 'C-MVT1', 'C-CAN1' |
| 500 | Technical error | The given {EVENT_DATE} is not correct or it is not filled, please send format : 'YYYY-MM-DDTHH:MI:SSZ' |
EXAMPLES
Cancel an hiring
{
"EMPLOYEE_ERP_ID": β9125874β,
"ERP_SOURCE": "SAP_DEβ,
"OSMOSE_CODE": β31059β,
"BU_ANALYTICAL_CODE": "12506",
"ACTION_REASON": "C-HIR1",
"EVENT_DATE": "2025-01-13T22:22:22Z"
}Erase an employee graduation
{
"EMPLOYEE_ERP_ID": β9125874β,
"ERP_SOURCE": "SAP_DEβ,
"OSMOSE_CODE": β31059β,
"BU_ANALYTICAL_CODE": "12506",
"ACTION_REASON": "C-GRAD",
"EVENT_DATE": "2025-01-13T22:22:22Z",
"VALUE": "2115",
"EFFECTIVE_DATE": "2024-08-31"
}Erase all skills of an employee
{
"EMPLOYEE_ERP_ID": β9125874β,
"ERP_SOURCE": "SAP_DEβ,
"OSMOSE_CODE": β31059β,
"BU_ANALYTICAL_CODE": "12506",
"ACTION_REASON": "C-SKILL",
"EVENT_DATE": "2025-01-13T22:22:22Z",
"VALUE": "*"
}